package com.bugmonkey.example;

import androidx.appcompat.app.AppCompatActivity;
import androidx.viewbinding.ViewBindings;

import android.content.Context;
import android.content.Intent;
import android.graphics.Bitmap;
import android.os.Bundle;

import com.bugmonkey.example.databinding.ActivityMain2Binding;
import com.bumptech.glide.Glide;

public class MainActivity2 extends AppCompatActivity {

    public static void start(Context context, String path) {
        Intent starter = new Intent(context, MainActivity2.class);
        starter.putExtra("path",path);
        context.startActivity(starter);
    }
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        ActivityMain2Binding binding = ActivityMain2Binding.inflate(getLayoutInflater());
        setContentView(binding.getRoot());

        Glide.with(this).load(getIntent().getStringExtra("path")).into(binding.imageView);
    }
}